Admin Mod CVARs used in v2.50 (detailed information below)
|
This is a listing of all of the server configuration variables (CVARs) specific to Admin Mod. You set these like any other server CVAR (such as mp_timelimit, etc).
NOTE: CVARs are no longer placed in your server.cfg!!! All Admin Mod CVARs (the ones listed here) are now located in the file half-life/<mod>/addons/adminmod/config/adminmod.cfg.
NOTE: This is not a list of Admin Mod commands. Rather, this is a list of all the server-side configuration variables you can use when you are configuring your Half-Life server.
Please note that a 'dedicated' server will, unless told otherwise, read it's initial settings from 'server.cfg'. A 'listen' server, on the other hand, reads them from 'listenserver.cfg' Executing your /<mod>/addons/adminmod/config/adminmod.cfg in server.cfg when you're running a listen server, and vice versa, means that the Admin Mod CVARs will NOT be loaded. A listen server is one that you start from within Half-Life itself: it starts when you join, it ends when you quit, and you have a 0 ping. A dedicated server is started from the HLDS program, and appears on the server machine as just lots of text information in a DOS-like console window.
Document notation standards
A cvar can either accept numeric ('123') or alphabetic ('abc') data. If it can accept alphabetic data, it will look like this in this document:
cvar_name "<string>"
If it can accept numeric data, it will look like this:
cvar_name <#>
Numeric data will either be '0' (disable or off), or anything else (enable or on). If the description of a cvar talks about it being 'enabled', that means non-zero (usually 1). Exceptions are noted. Note that if a cvar is not explicitly set, it defaults to 0 (disabled).
In addition to these standard types of cvar Admin Mod uses what we call "options cvars".
An options cvar takes a string data but that string can be used to set many different name-value pairs.
The standard format for setting an options cvar is this.
Each option is a pair comprised of a name string followed by a value.
If the value is numeric there should be no space between
the name and the value.
If the value is a string then there should be one space between
the name and the string.
Pairs are separated using the colon character
( : ).
It sounds complicated but it's not, here's an example
admin_beta_enable "nc0:ssl on"
that sets the option nc to 0 and the option ssl to "on". Many of these options can be
combined into a single cvar setting allowing more configurability without using many
more cvars and making older settings obsolete. Look at the list on the right, I'm
sure you begin to appreciate how using less cvars is a good idea. It can quickly
become confusing when you are dealing with many at once.
In the descriptions below, examples of how to write the cvar are provided. Reading this entire document is a good idea if you are planning to do much at all with the Admin Mod.
About "relative directories" and files
Cvars that represent files are said to be 'relative' to a directory
(usually the <mod>
directory). This means the file name
should be treated as if looking from the specified 'relative' directory.
As an example, admin_plugin_file is relative to the <mod>
directory; if I'm running a TFC server, my <mod>
directory might
be C:\HLServer\TFC. If I wanted my plugin file to be at
C:\HLServer\TFC\addons\adminmod\config\plugin.ini
, I would simply set admin_plugin_file to
addons/adminmod/config/plugin.ini
.
Miscellaneous Notes
If vote_freq is not defined voting will be disabled.
If map_ratio is not defined map voting is disabled.
If kick_ratio is not defined kicking will be disabled.
If models_file is not defined model passwords will be disabled.
If nicks_file is not defined nick reservation will be disabled.
If maps_file is not defined then users can vote for any map in the mapcycle.txt file. If it is defined, all votable maps must be included in the file indicate by the maps_file cvar (typically this file would be named maps.ini)
You can un-define or make null any variable by setting to 0 like this: nicks_file 0
Used by the TFC plugin. If enabled, an attempt to switch teams will be rejected if it would unbalance the teams (unless the team being switched to, or the team being switched from, has less than two people) . If disabled, people can switch teams freely.
When running bots on the server, setting this variable to "1" will protect bots from exec_client commands in Admin Mod, and thus prevent bot related server crashing problems.
admin_connect_msg "<string>"
admin_connect_msg "All your base are belong to Jaguar."
Used by the message plugin. This is the message that will be displayed to everyone thirty seconds after connecting to the server. Setting admin_connect_msg to "0" will not display a connect message, although the timer is run.
Used by the CS plugin. If enabled, the CS plugin's weapon restrictions go into effect (if any are set, that is). If disabled, the CS weapon restrictions are ignored (if any are set).
admin_debug <#>
If enabled, your logs will be filled with lots and lots of debugging messages related to Admin Mod. Not recommended for general use.
admin_fun_mode <#>
Used by the Fun plugin. Determines whether or not the fun commands are allowed.
admin_fx <#>
Enables special effects to accompany certain commands, such as teleport and slap.
admin_gag_name <#>
Used by the retribution plugin. If enabled, people who are gagged will be unable to change their name while gagged. If disabled, people who are gagged will be able to change their names as normal.
Used by the retribution plugin. If enabled, people who are gagged will not be able to use the say_team command. If disabled, people who are gagged will be able to use the say_team command as normal.
admin_highlander <#>
There can be only one! Normally (when disabled), everyone gets the access assigned to them. If admin_highlander is enabled, only the person with the highest access actually gets their's; everyone else gets the default. Thus, only one admin (the one with the highest access level)will be able to execute commands at any given time.
This is referenced by CheckImmunity() in adminlib.inc.
Normally (when disabled), people with ACCESS_IMMUNITY (4096) become
immune to many of the other admin commands (though not to straight rcon).
If admin_ignore_immunity is enabled, ACCESS_IMMUNITY is ignored
and does nothing.
admin_plugin_file "<string>"
admin_plugin_file "plugin.ini"
This is the file to load plugins from.
It should be relative to the <mod>
directory (e.g., for
TFC, it should be relative to the half-life\tfc
directory). If
this cvar exists, the plugin-style of scripting will be used.
If it does not exist, the single-script style of scripting will be
used (see script_file). Note that, regardless of where this
file is situated, the plugins it referenced are relative to the
<mod>
dir, _not_ the location of the plugin file (eg, if the
admin_plugin_file is <mod>\AdminMod\plugin.ini
, the plugins
referenced will still be relative to <mod>
not <mod>\AdminMod
).
from Admin mod 2.50.58 onwards this cvar can be set to a directory name.
All plugins located in the directory specified will be loaded in alphabetical
order by Admin Mod. For example settings admin_plugin_file to addons/scripts
in a default installation will load all the provided plugins from that directory.
admin_reconnect_timeout 300
This is the time that a password is considered to stay valid after the player has disconnected from the server. If the player reconnects to the server within <#> seconds using the same name and the same IP, he does not have to reenter his password first. Don't set this value too high.
admin_reject_msg "<string>"
admin_reject_msg "This is a restricted command which you cannot use."
This message is displayed to users who try to execute commands that they don't have the appropriate access rights for.
admin_repeat_freq 300
Used with the admin_repeat_message cvar. This determines how often (in seconds) the "pretty say " repeat message appears on the screen. The repeat message frequency can be set with admin_repeat_freq. The units are seconds. The minimum value is 15 seconds. Setting it to 0 will not start the timer. The timer cannot be started by setting it to a different value during a map. It will only be started at a map change.
admin_repeat_msg "<string>"
admin_repeat_msg "Don't look now! They're right behind you!"
Used by the message plugin. This is the message that is shown to everyone on the server in the center of the screen. Setting admin_repeat_msg to "0" will not display a repeat message, but the timer is not killed if it was started. It will continue to run, and setting admin_repeat_msg to a different value will again display that string.
admin_quiet <#>
admin_quiet 0
admin_quiet 1
admin_quiet 2
This is referenced by SayCommand() in adminlib.inc.
Here's how it functions by default:
Certain commands override admin_quiet (such as those found in the cheating plugin). These over-riding commands, when used, will always show the message 'ADMIN Command: <Player> used <command>" regardless of what value this cvar is set to.
If admin_quiet is 0, executing admin command on others will result in the command being executed and the message 'ADMIN Command: <Player> used <command>' being displayed to all players.
b>If admin_quiet is 1, the same effect occurs as with the "0" value: Admin Mod will display the message 'ADMIN Command: Admin used <command>' but will not identify the admin by name.
For any other value of admin_quiet (for example, "admin_quiet 2"), all commands will not display a message at all, but will only get logged, with the exception of the commands that over-ride the cvar as mentioned above (generally these are commands that would be considered cheating if no one knew they were being executed).
admin_vault_file "<string>"
admin_vault_file "vault.ini"
This file will be used to store configuration data across maps and even across server incarnations.
admin_version "<string>"
Returns the current Admin Mod version of the DLL. Setting this does nothing.
Used by the HLFD map vote plugin. If enabled, a HALFD-style map vote will automatically start five minutes before the end of a map. If disabled, it won't.
admin_vote_echo <#>
If set to 1, when a vote is in progress
the option a user voted for is echoed to all clients in the format:
<player> voted for option #<option number>
admin_vote_freq <#>
This is the number of seconds that must elapse after the start of the map, or the end of another vote, before another HALFD- style map vote can be called by someone without the ACCESS_CONTROL_VOTE access. NOTE: If you don't have it explicitly set in in your .cfg, it defaults to 600 (ten minutes). If 0, then _only_ those people with ACCESS_CONTROL_VOTE may call for votes. Note that this only controls the HALFD-style votes; for the HL menu-style votes, see vote_freq.
Used by the HLFD map vote plugin. Controls how many times the current map can be extended for thirty minutes (e.g., admin_vote_maxextend 2 would allow for, at most, two extensions). If set to zero or a negative number, the current map can never be extended.
admin_vote_ratio <#>
Used by the HLFD map vote plugin. Controls the percent of the players who have to vote for a map to get it to win (note that this ratio applies only to the HALFD-style map vote. For the admin_vote_map, see map_ratio, below). If zero or negative, whichever map gets the most votes wins. Otherwise, a map must get at least (admin_vote_ratio * playercount / 100) votes to win (e.g., if the admin_vote_ratio is 60, and there are 10 people on, a map must get at least (60 * 10 / 100) = 6 votes to win.)
alarm_message "<string>"
This cvar is no longer used.
alarm_time <#>
This cvar is no longer used.
This controls whether or not the execclient() scripting function is enabled in the Admin Mod DLL. If enabled, execclient() is enabled; if disabled, execclient() is disabled. Enabling execclient() functionality allows scripts to execute commands remotely on players.
amv_autoban <#>
This cvar is no longer available in Admin mod 2.50.50 onwards,
please see the amv_anti_cheat_options Cvar.
amv_anti_cheat_options (options cvar)
Option: Name Crash Cheat.
id: nc
Values:
Option: Spectator Cheat.
id:sc
Values:
For example: amv_anti_cheat_options nc2:sp1
For more detail see the Whats new in Admin Mod section.
amv_enable_beta (options cvar)
An Admin Mod version may include also some beta features. These are features which aren't considered stable enough or which haven't got tested enough to be considered part of the released version. They are still included to provide a broader audience with the possibility to test them and to see if they like them. These features are disabled by default and have to be explicitly enabled with this cvar. Note, that they may cause instabilities to your server when enabled and that they are not guaranteed to work as expected.
Option: Client Menus
id: menu
Description: Enable the admin to use GUI menus like the buy menus in CS to execute Admin Mod commands.
Requires a plugin which provides a menu system.
Values:
Option:Check for broken entities
id: melog
Description: Some server admins report that their servers sometimes have missing or non-functional
entities. This is a temporary feature to help diagnose these errors. When turned on, it will check
all entities and report those that it suspects to be broken or missing to the log file.
Values:
Option: Fix broken entities
id:mefix
Description: If a broken entity is found, Admin Mod can try and fix it so that it works again.
This option controls if Admin Mod should attempt to fix broken entities.
Values:
When set to 0, and debug is enabled, Admin Mod passwords will not be logged in cleartext.
Enables private server mode. This allows only users who have authorisation either via the users.ini or the ips.ini files to gain access to the server. All others attempting to join will be refused access and give the amv_prvt_kick_message cvar message.
amv_prvt_kick_message "<string>"
If the server is set to private using the amv_private_server cvar users who are not authorised to connect will see this message in their consoles.
If a user with admin access disconnects and upon reconnect gets put into a different server slot than the one he occupied before, he will loose his access rights. This cvar controls the time during which an admin will keep his access rights even if he joins into a different server slot. The maximum is 90 seconds. Setting it to 0 disables this.
amv_register_cmds "<string>"
This cvar is only of interest to other Metamod plugin developers. Space separated list of registering commands similar to "logd_reg" of LogD and "sm_register" of StatsMe to allow the use of "admin_command" with the exec() scripting function.
(def:30) Defines the max time length in seconds of voting process. The minimum is 2, and the maximum is 1800.
default_access <#>
This controls the default access that people get (aside from being granted special user privileges). It works exactly like the user level access rights, but everyone gets it.
encrypt_password <#>
NOTE: If you don't have it explicitly set in your .cfg, it is SET TO 1. This determines whether or not the passwords people enter for their user privileges are encrypted on the server. Admin Mod supports different methods of password encryption:
MySQL only
MySQL PASSWORD: When this variable is set to 3 Admin Mod expects passwords stored in
MySQL tables to be encrypted with the MySQL SQL statement PASSWORD().
file_access <#>
This cvar is no longer used. See file_access_read, file_access_write.
file_access_read <#>
This controls whether or not the scripting functions are allowed to read files on the server. If enabled, the scripting functions are; if disabled, they are not.
This controls whether or not the scripting functions are allowed to write to files on the server. If enabled, the scripting functions are; if disabled, they are not.
help_file "<string>"
help_file "admin_help.cfg"
This is not used for the plugin-style scripting; if you have admin_plugin_file defined, this cvar is ignored. If you are using the old single-script style, this is the file to load the help information from. It is relative to the <mod> directory.
ips_file "<string>"
ips_file "ips.ini"
If you're using MySQL, this cvar is ignored (see mysql_dbtable_ips). Otherwise, this is the file (relative to the <mod> dir) that priority IPs are loaded from. NOTE: If you don't have it explicitly set in your .cfg, it is 'ips.ini'. Priority IPs are those that are allowed to take a reserved spot (if any are set up) without a password.
kick_ratio <#>
Used by admin_vote_kick. This is the ratio of players who must vote 'yes' to a kick for it to be successful. e.g. if the kick_ratio is 60, and there are 20 people on the server, 12 of them must vote 'yes' to a kick vote for it to be successful.
map_ratio <#>
Used by admin_vote_map. This is the ratio of players who must vote 'yes' to a map change for it to be successful. e.g., if map_ratio is 40, and there are 20 people on the server, 8 of them must vote 'yes' to a map vote for it to be successful. Note that this cvar does not control the HALFD-style map vote; see admin_vote_ratio.
maps_file "<string>"
maps_file "maps.ini"
A list of maps available during map votes. This list can contain maps not listed in your regular server map cycle, or it can contain a limited number of maps if you want to restrict voting to just a few maps. If you disable it (by setting the value to "0"), the list of votable maps will instead be taken from your mapcycle.txt
models_file "<string>"
models_file "models.ini"
If you're using MySQL, this cvar is ignored (see mysql_dbtable_models). Otherwise, this is the file (relative to the <mod> dir) that reserved models are loaded from.
models_kick_msg "<string>"
models_kick_msg "This model is reserved."
This is the message shown to someone who gets kicked for trying to use a reserved model.
mysql_dbtable_ips "ips"
If you're not using MySQL, this cvar is ignored (see ips_file). Otherwise, this is the database table to get the priority IP information from. Priority IPs are those that are allowed to take a reserved spot (if any are set up) without a password.
mysql_dbtable_models "<string>"
mysql_dbtable_models "models"
If you're not using MySQL, this cvar is ignored (see models_file). Otherwise, this is the database table to load the reserved model names from.
mysql_dbtable_plugins "<string>"
mysql_dbtable_plugins "plugins"
If you're not using MySQL, this cvar is ignored (see users_file). Otherwise, this is the database table to load the plugins from.
mysql_dbtable_users "<string>"
mysql_dbtable_users "users"
If you're not using MySQL, this cvar is ignored (see users_file). Otherwise, this is the database table to load the privileged names from.
mysql_dbtable_words "<string>"
mysql_dbtable_words "words"
If you're not using MySQL, this cvar is ignored (see words_file). Otherwise, this is the database table to load the swear words from.
mysql_host "<string>"
mysql_host "127.0.0.1"
If you're not using MySQL, this cvar is ignored. Otherwise, it's the address of the host the MySQL database exists on.
mysql_pass "<string>"
mysql_pass "milk"
If you're not using MySQL, this cvar is ignored. Otherwise, it's the password used to connect to the MySQL database.
mysql_use_sqlPASSWORD <#>
When enabled, uses encryption algorithm PASSWORD( ) instead of the default crypt( )
mysql_user "<string>"
mysql_user "moocow"
If you're not using MySQL, this cvar is ignored. Otherwise, it's the username used to connect to the MySQL database.
nicks_kick_msg "<string>"
nicks_kick_msg "This name is reserved."
This is the message shown to someone who gets kicked for trying to use a name that has reserved access (16384).
password_field "<string>"
password_field "_pw-home"
This is the setinfo field that people need to enter their password into on the client before connecting to the server, if they wished to be authorized at connect time. NOTE: If you don't have it explicitly set in your .cfg, it is 'pw'. As an example, if the password_field is 'pw-home', and there is a user whose password is "milk", then the setinfo line in the user's adminpass.cfg would be 'setinfo "_pw-home" "milk"'.
N.B.
From Admin Mod 2.50.50 onwards using an underscore as the first character of the password
field is now compulsory. The change to the secure underscore including forms was made
several versions previously but was not enforced. Unfortunately not all users took notice
and passwords were left in the clear for cheats to find and exploit. With compulsory
first character underscores the server will print a warning message and then quit if a
password_field not beginning with underscore is used. This behavior is added to ensure
better security for both client and server.
password_timeout <#>
This cvar is no longer used. It is no longer present in 2.50.38 onwards.
pretty_say <#>
This cvar controls how the centersay() script function works. NOTE: If you don't have it explicitly set in your .cfg, it is ENABLED. If pretty_say is enabled, centersay() fades in and out and does some other tricks. If it's disabled, centersay() just appears as normal text in the middle of the screen.
Returns the number of slots free on the server (after taking into account reserved slots). Setting this does nothing.
reserve_slots <#>
Controls how many of the server's slots are reserved. This is useful only if reserve_type, below, is either 0 or 2.
reserve_slots_msg "<string>"
reserve_slots_msg "There are no free slots available."
This is the message shown to someone who gets kicked when there are only reserved slots left on the server, and they do not have reserved access.
reserve_type <#>
This controls how reserve slots work on the server (the default is 0).
script_file "<string>"
This variable is depreceated and will be removed in a future version of Admin Mod. Don't use it anymore. Instead, use plugins and the admin_plugin_file variable.
use_regex <#>
If enabled, names are compared to those who have privileges with regular expressions; otherwise, they are compared with a straight match. Using regular expressions is useful for matching parts of names (such as clan tags), whereas, without use_regex, you would have to add each name with that tag you wanted to assign privileges to.
users_file "<string>"
users_file "users.ini"
If you're using MySQL, this cvar is ignored (see mysql_dbtable_users). Otherwise, this is the file (relative to the <mod> directory) that privileged names are loaded from.
vote_freq <#>
This is the minimum number of seconds allowed between votes called with the vote() scripting function (such as admin_vote_kick and admin_vote_map). If 0 or disabled, the vote() scripting function is disabled. Note that this delay also applies to the beginning of the map; if vote_freq is 240 (240 seconds = 4 minutes), admin_vote_kick and admin_vote_map won't work for the first four minutes of the map, as well as for the four minutes following any previous admin_vote_kick or admin_vote_map. Note that this only applies to HL vote-style votes for HLFD-style votes, see admin_vote_freq.
vote_freq_kick <#>
This cvar is no longer used. See vote_freq.
vote_freq_map <#>
This cvar is no longer used. See vote_freq.
words_file "<string>"
words_file "wordfile.txt" ;This is the file containing the list of words that will match the check_words() and censor_words() functions (useful for swear word detection). Note that these words are case-insensitive.